//
//  ViewController.m
//  10509
//
//  Created by student on 16/2/20.
//  Copyright © 2016年 NIIT. All rights reserved.
//

#import "ViewController.h"

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view, typically from a nib.
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

- (IBAction)JiSuanBtn:(id)sender {
    float area1 = [self.lengthText.text floatValue] * [self.WidthText.text floatValue];
    self.AreaText.text = [NSString stringWithFormat:@"%.2f",area1];
    
    float area2 = [self.RadiusText.text floatValue] * [self.RadiusText.text floatValue] * M_PI;
    self.AreaText2.text = [NSString stringWithFormat:@"%.2f",area2];
}
- (IBAction)backTap:(id)sender {
    [self.view endEditing:YES];
}

@end
